<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of IndexController
 *
 * @author Admin
 */
class Dashboard_IndexController extends Zend_Controller_Action
{
    protected $_model;
    protected $_authService;

    public function init()
    {
        $layout = $this->_helper->layout();
        $layout->setLayout('main');

        $this->_model = new Main_Model_AdminUser();

        $this->_authService = new Main_Service_Authentication();
    }

    public function indexAction()
    {
        /*
        if (!$this->_helper->acl('Admin')) {
             echo '<br> ur not admin';
            }
         */
        // checking if user is logged in
        if(!$this->_authService->getAuth()->hasIdentity())
            $this->_redirect('/');
    }
}
?>
